package sctu.edu.java.year2016.team05.zengkun.day20160615.UserPackge.KnowledgBase;

import sctu.edu.java.year2016.team05.zengkun.day20160615.UserPackge.Forhelp;
import sctu.edu.java.year2016.team05.zengkun.day20160615.UserPackge.SearchPackge.Allquestion;

import java.util.Scanner;

/**
 * Created by mike on 2016/6/15.
 */
public class MainBorad {


    public static void run() {
        {
            System.out.println("电脑故障目录检索：\n 1.主板   2.播放器  3.内存   4.CD驱动器  " +
                    "5.键盘  6.调制解调器  7.屏幕  8.声卡  9.请求人工服务  10.维修人员已解决方案\n\n" +
                    "11.电脑故障关键字查询：" +
                    "\n请输入目录数字即可进入相关问题查询");

            Allquestion allquestion = new Allquestion();
            Scanner scan = new Scanner(System.in);
            int no = scan.nextInt();

            switch (no) {
                case 1:
                    Knodled knodled = new Knodled();
                    knodled.board();
                    break;
                case 11:
                    allquestion.Search();
                    break;
                case 10:
                    Surface.see();
                    break;
                case 9:
                    Forhelp forhelp = new Forhelp();
                    forhelp.help();
                     break;
                default:
                    System.out.println("输入错误");

            }
        }

    }

    public static void choose() {
        Scanner scanner = new Scanner(System.in);
        String test = scanner.next();
        if (test.equals("客户"))
            MainBorad.run();
        else if (test.equals("维修人员"))

        {
Surface.question0();

        } else if (!test.equals("客户") || !test.equals("维修人员"))

        {
            System.out.println("输入错误，请从新输入");
            MainBorad.choose();

        }

    }
}

